<%@page contentType="text/html" pageEncoding="UTF-8"%>
<%@taglib prefix="f" uri="http://java.sun.com/jsf/core" %>
<%@taglib prefix="h" uri="http://java.sun.com/jsf/html" %>
<%@taglib prefix="rich" uri="http://richfaces.org/rich" %>
<%@taglib prefix="a4j" uri="http://richfaces.org/a4j" %>

<html>
    <head>
        <link rel="stylesheet" type="text/css" href="../css/popup.css"/>
        <link rel="stylesheet" type="text/css" href="../css/kapiform.css"/>
        <link rel="stylesheet" type="text/css" href="../css/thickbox.css"/>
        <script type="text/javascript" language="javascript" src="../scripts/jQuery/thickbox.js"></script>
        <script type="text/javascript" language="javascript" src="../scripts/jQuery/kapi.js"></script>
        <style type="text/css">
            #ui-datepicker-div
            {
                z-index: 9999999;
            }
            .record_row_left a:hover{color:black}

  .blue{
                background: #E0EFFC;
            }
            .white{
                background: #FFFFFF;
            }
        </style>

    </head>



    <script type="text/javascript">
        $j(document).ready(function(){
            initThickBox('.thickbox');
        });
    </script>
    <body>
        <f:view>
            <f:loadBundle basename="#{environmentSession.localizationSource}" var="locale"/>
            <a4j:form >
                <div class="content_detail">
                    <div class="list_item_user">
                        <div class="item_content" style="display: block">
                            <div class="infomation_form">
                                <div class="card_add" style="margin-left:11px; padding:0px">
                                    <h:outputLink rendered="#{documentController.add}"  value="uploadfile.jsp?pn100=#{documentController.pn100}&pm650=none&page=#{uploadController.pagereload}&type=ALL&table=N100&KeepThis=true&amp;TB_iframe=true&amp;height=350&amp;width=550&amp;modal=true" styleClass="thickbox" id="thickbox2"  >
                                        <img src="../images/add_tab.png" alt="add" title="add" /><h:outputText value="#{locale.attach_document}"/>
                                    </h:outputLink>
                                </div>
                                <div style="float:left ; width:100%; min-height:110px;">
                                    <%--        <div style="float:left; width:150px; height:200px; margin:0px 10px 10px 10px;">
                                                <h:outputLink  value="uploadfile.jsp?pn100=#{documentController.pn100}&pm650=#{documentController.pm650}&height=165px&width=410px" styleClass="fancybox" id="fancybox"  >
                                                    <img src="<h:outputText value="#{documentController.avata}"/>" width="150" height="200" alt="" />
                                                </h:outputLink>
                                            </div> --%>
                                    <h:inputHidden id="idpm650" value="#{documentController.pm650}" />
                                    <div style="float:left; width:100%; min-height:100px; height:auto;">
                                        <div class="record_row_upload_main">                                       
                                        <!--    <div class="record_row_upload_head" style="display:<h:outputText value="#{documentController.flag}"/>;">
                                                <div class="record_row_c1">Tên File</div>
                                                 <div class="record_row_c5">Mô tả</div>
                                                <div class="record_row_c2">Ngày cập nhật</div>
                                                <div class="record_row_c3">Người cập nhật</div>
                                                <div class="record_row_c4"></div>
                                            </div> -->
                                           

                                         <!--       <div class="record_row_upload_content">
                                                    <div class="record_row_c1">
                                                        <a target="_Bank" href="<h:outputText value="#{item.download}" />"><h:outputText value="#{item.mv652}" /> </a>
                                                    </div>
                                                      <div class="record_row_c5"><a><h:outputText value="#{item.mv651}" /> </a></div>
                                                    <div class="record_row_c2">
                                                        <a>  <h:outputText value="#{item.ml668}"><f:convertDateTime pattern="dd/MM/yyyy"/></h:outputText></a>

                                                    </div>
                                                    <div class="record_row_c3"> <a> Trần Nhân Viên</a></div>
                                                    <div class="record_row_c4">
                                                        <h:outputLink  rendered="#{documentController.delete}"    value="delete.jsp?id=#{item.pm650}&pn100C=#{documentController.pn100}&page=#{uploadController.pagereload}&flag=M650&height=150px&width=300px" styleClass="fancybox">
                                                            <img src="../images/delete_1.png" alt="delete"  title="delete" />
                                                        </h:outputLink></div>
                                                </div> -->
                                                        <rich:dataTable value="#{documentController.listdocument}" var="item"
                                                                        rows="50"  rendered="#{!empty documentController.listdocument}" rowClasses="blue, white"
                                                                                                    
                                                                                                    style=" margin-left:10px;width:98%"
                                                                                                    width="94%" rowKeyVar="index"
                                                                                                    id="table" >

                                                                                         <rich:column style="width:25px;">
                                                                                            <f:facet name="header">
                                                                                                <h:outputText value="STT" />
                                                                                            </f:facet>
                                                                                            <div style="width:25px; text-align: center">
                                                                                                <h:outputText value="#{index+1}" />

                                                                                            </div>
                                                                                        </rich:column>
                                                                                        <rich:column style="width:280px;">
                                                                                            <f:facet name="header">
                                                                                                <h:outputText value="#{locale.file_name}" />
                                                                                            </f:facet>
                                                                                            <div style="width:280px; text-align: left">
                                                                                                 <h:outputLink     value="#{item.download}"  target="_Bank" >
                                                                                                   <h:outputText value="#{item.mv652}" />
                                                                                                </h:outputLink>
                                                                                             
                                                                                            </div>
                                                                                        </rich:column>

                                                                                        <rich:column >
                                                                                            <f:facet name="header">
                                                                                                <h:outputText value="#{locale.description}" />
                                                                                            </f:facet>

                                                                                            <div style="width:auto; text-align: left">
                                                                                                <h:outputText value="#{item.mv651}" />
                                                                                            </div>
                                                                                        </rich:column>


                                                                                           <rich:column  width="160px">
                                                                                            <f:facet name="header">
                                                                                                <h:outputText value="#{locale.date_update}" />
                                                                                            </f:facet>

                                                                                            <div style="width:160px; text-align: center">
                                                                                                <h:outputText value="#{item.ml668}"><f:convertDateTime pattern="dd/MM/yyyy"/></h:outputText>
                                                                                            </div>
                                                                                        </rich:column>
                                                                                          <rich:column  width="160px">
                                                                                            <f:facet name="header">
                                                                                                <h:outputText value="#{locale.person_update}" />
                                                                                            </f:facet>

                                                                                            <div style="width:160px; text-align: center">
                                                                                                <h:outputText value="#{item.ml669}" />
                                                                                            </div>
                                                                                        </rich:column >
                                                                                        <rich:column style="width:25px;">
                                                                                            <f:facet name="header">
                                                                                                <h:outputText value="Action" />
                                                                                            </f:facet>
                                                                                            <div style="width:25px; text-align: center">
                                                                                                <h:outputLink  rendered="#{documentController.delete}"    value="delete.jsp?id=#{item.pm650}&pn100C=#{documentController.pn100}&page=#{uploadController.pagereload}&flag=M650&height=150px&width=300px" styleClass="fancybox">
                                                                                                    <img src="../images/delete_1.png" alt="delete"  title="delete" />
                                                                                                </h:outputLink>

                                                                                            </div>
                                                                                        </rich:column>
                                                               </rich:dataTable>
                                           
                                        </div>
                                    </div>

                                </div>
                            </div>
                        </div>
                    </div>
                </div>
                <rich:modalPanel id="ajaxLoadingModalBox" minHeight="30" minWidth="40"
                                 height="30" width="40" zindex="2000">
                    <h:outputText value="#{locale.please_wait}" styleClass="startDummer"></h:outputText>
                </rich:modalPanel>
            </a4j:form>
        </f:view>
    </body>
</html>